//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package com.jtny.nytb.equipment.enums;

public enum DataParamSourceEnum {
    SYSTEM_AUTO_COLLECT(1, "设备自动采集"),
    SYSTEM_CALCULATE(2, "系统计算"),
    CONSTANT(3, "常量"),
    MANUAL_FILL(4, "手动填报");

    private Integer code;
    private String name;

    public static String getNameByCode(Integer code) {
        DataParamSourceEnum[] var1 = values();
        int var2 = var1.length;

        for(int var3 = 0; var3 < var2; ++var3) {
            DataParamSourceEnum value = var1[var3];
            if (value.getCode().equals(code)) {
                return value.getName();
            }
        }

        return null;
    }

    public static Integer getCodeByName(String name) {
        DataParamSourceEnum[] var1 = values();
        int var2 = var1.length;

        for(int var3 = 0; var3 < var2; ++var3) {
            DataParamSourceEnum value = var1[var3];
            if (value.getName().equals(name)) {
                return value.getCode();
            }
        }

        return null;
    }

    private DataParamSourceEnum(Integer code, String name) {
        this.code = code;
        this.name = name;
    }

    public Integer getCode() {
        return this.code;
    }

    public String getName() {
        return this.name;
    }
}
